#include<iostream>
#include<unistd.h>
#include<thread>
using namespace std;
int main()
{
    cout<<"main   thread begin"<<endl;
    auto func = []{
        cout<<"lambda thread begin"<<endl;
        cout<<"lambda thread end  "<<endl;
    };

    thread p1(func);
    p1.join();

    cout<<"main   thread end  "<<endl;

    return 0;
}